<?xml version="1.0" encoding="iso-8859-1"?>
<!DOCTYPE html 
     PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
     "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">

<html>
<head>
  <title>run (Spec::Runner::CommandLine)</title>
  <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
  <link rel="stylesheet" href="../../../.././rdoc-style.css" type="text/css" media="screen" />
</head>
<body class="standalone-code">
  <pre><span class="ruby-comment cmt"># File vendor\plugins\rspec/lib/spec/runner/command_line.rb, line 12</span>
      <span class="ruby-keyword kw">def</span> <span class="ruby-keyword kw">self</span>.<span class="ruby-identifier">run</span>(<span class="ruby-identifier">argv</span>, <span class="ruby-identifier">err</span>, <span class="ruby-identifier">out</span>, <span class="ruby-identifier">exit</span>=<span class="ruby-keyword kw">true</span>, <span class="ruby-identifier">warn_if_no_files</span>=<span class="ruby-keyword kw">true</span>)
        <span class="ruby-identifier">old_behaviour_runner</span> = <span class="ruby-keyword kw">defined?</span>(<span class="ruby-identifier">$behaviour_runner</span>) <span class="ruby-operator">?</span> <span class="ruby-identifier">$behaviour_runner</span> <span class="ruby-operator">:</span> <span class="ruby-keyword kw">nil</span>
        <span class="ruby-identifier">$behaviour_runner</span> = <span class="ruby-constant">OptionParser</span>.<span class="ruby-identifier">new</span>.<span class="ruby-identifier">create_behaviour_runner</span>(<span class="ruby-identifier">argv</span>, <span class="ruby-identifier">err</span>, <span class="ruby-identifier">out</span>, <span class="ruby-identifier">warn_if_no_files</span>)
        <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">$behaviour_runner</span>.<span class="ruby-identifier">nil?</span> <span class="ruby-comment cmt"># This is the case if we use --drb</span>

        <span class="ruby-identifier">$behaviour_runner</span>.<span class="ruby-identifier">run</span>(<span class="ruby-identifier">argv</span>, <span class="ruby-identifier">exit</span>)
        <span class="ruby-identifier">$behaviour_runner</span> = <span class="ruby-identifier">old_behaviour_runner</span>
      <span class="ruby-keyword kw">end</span></pre>
</body>
</html>